<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>Nfc Info: TagImageCache Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  <td id="projectlogo"><img alt="Logo" src="NfcInfo80.png"/></td>
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Nfc Info
   
   </div>
   <div id="projectbrief">Shows all information about NFC tags available through Qt Mobility APIs. Includes reusable convenience classes for handling additional tag types: Smart Poster, Image and vCard.</div>
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">TagImageCache Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="TagImageCache" -->
<p>Caches any images found on tags in memory, for retrieval and display in the QML user interface.  
 <a href="class_tag_image_cache.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="tagimagecache_8h_source.html">tagimagecache.h</a>&gt;</code></p>

<p><a href="class_tag_image_cache-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_tag_image_cache.html#a86d61193a833ec7bdc105a171954638f">addImage</a> (QImage img)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Add an image to the cache. Returns the id, which can then be requested from QML.  <a href="#a86d61193a833ec7bdc105a171954638f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">QImage&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_tag_image_cache.html#a43fbd349466fd167c8ad573a801d3ce3">requestImage</a> (const QString &amp;id, QSize *size, const QSize &amp;requestedSize)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Request an image from the cache by specifying its <em>id</em>.  <a href="#a43fbd349466fd167c8ad573a801d3ce3"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Caches any images found on tags in memory, for retrieval and display in the QML user interface. </p>
<p>The class is derived from QDeclarativeImageProvider and uses the QImage operation mode. </p>
</div><hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a86d61193a833ec7bdc105a171954638f"></a><!-- doxytag: member="TagImageCache::addImage" ref="a86d61193a833ec7bdc105a171954638f" args="(QImage img)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int TagImageCache::addImage </td>
          <td>(</td>
          <td class="paramtype">QImage&#160;</td>
          <td class="paramname"><em>img</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Add an image to the cache. Returns the id, which can then be requested from QML. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">img</td><td>the image to add to the cache. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a43fbd349466fd167c8ad573a801d3ce3"></a><!-- doxytag: member="TagImageCache::requestImage" ref="a43fbd349466fd167c8ad573a801d3ce3" args="(const QString &amp;id, QSize *size, const QSize &amp;requestedSize)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">QImage TagImageCache::requestImage </td>
          <td>(</td>
          <td class="paramtype">const QString &amp;&#160;</td>
          <td class="paramname"><em>id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">QSize *&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const QSize &amp;&#160;</td>
          <td class="paramname"><em>requestedSize</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Request an image from the cache by specifying its <em>id</em>. </p>
<p>Request the image if possible in <em>requestedSize</em>. The image will be scaled keeping its aspect ratio. The final size is stored in <em>size</em>. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>the requested image from the cache, or an empty QImage() otherwise. </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="tagimagecache_8h_source.html">tagimagecache.h</a></li>
<li>tagimagecache.cpp</li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>



<hr class="footer"/><address class="footer"><small>
Generated on Mon Aug 29 2011 22:30:52 for Nfc Info by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.5.1
</small></address>

</body>
</html>
